package com.kaola.qrcodescanner.qrcode;

import android.content.Intent;
import android.os.Bundle;
import android.support.v7.app.AppCompatActivity;
import android.support.v7.widget.Toolbar;
import android.view.View;

import com.kaola.qrcodescanner.R;

public class MainActivity extends AppCompatActivity {

    @Override
    protected void onCreate(Bundle savedInstanceState) {
        super.onCreate(savedInstanceState);
        setContentView(R.layout.activity_main);
        Toolbar toolbar = (Toolbar) findViewById(R.id.toolbar);
        setSupportActionBar(toolbar);

    }


    public void onClick(View view) {
        switch (view.getId()) {
            case R.id.decode:
                startActivity(new Intent(this, QrCodeActivity.class));
                break;
            case R.id.encode:
                startActivity(new Intent(this, EncodeActivity.class));
                break;
        }
    }
}
